﻿<?php include_once("db_config.php");?>
<!DOCTYPE html>
<html lang="<?php echo $lang;?>">
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <meta name="description" content="">
    <meta name="author" content="ysfl" >
    <link rel="icon" href="img/favicon.ico">
    <title><?php echo $name; echo $title;?></title>
    <link href="css/bootstrap.min.css" rel="stylesheet">
    <link href="css/jumbotron.css" rel="stylesheet">
    <script src="js/jquery.min.js"></script>
    <script src="js/jquery.function.js"></script>
    <script src="js/ie-emulation-modes-warning.js"></script>
    <!--[if lt IE 9]>
      <script src="js/html5shiv.min.js"></script>
      <script src="js/respond.min.js"></script>
    <![endif]-->
  </head>
  <body>
    <nav class="navbar navbar-inverse navbar-fixed-top" style="background-color: #52D1C8;" role="navigation">
      <div class="container">
        <div class="navbar-header">
          <button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#navbar" aria-expanded="false" aria-controls="navbar">
            <span class="sr-only">Toggle navigation</span>
            <span class="icon-bar"></span>
            <span class="icon-bar"></span>
            <span class="icon-bar"></span>
          </button>
          <a class="navbar-brand"  style="" href="#"><?php echo $name;?></a>
        </div>
        <div id="navbar" class="navbar-collapse collapse">
            <?php
                session_start();
                //检测是否登录，若没登录则转向登录界面
                if(!isset($_SESSION["userid"])){
                    echo '
                      <span class="navbar-form navbar-right">
                        <a class="btn btn-danger" href="./admin/reg.php">员工注册</a>
                        <a class="btn btn-success" href="./admin/login.php">员工登陆</a>
                      </span>
                    ';
                }
                else {
                      echo '
                          <ul class="nav navbar-nav navbar-right">
                            <li><a href="#">'. $_SESSION["level"].':'. $_SESSION["username"].'</a></li>
                            <li><a href="./admin">进入后台</a></li>
                            <li><a href="#" id="logout">退出登陆</a></li>
                        </ul>
                      ';
                }
            ?>
        </div><!--/.navbar-collapse -->
      </div>
    </nav>
            <!-- Login info -->
            <div class="modal fade" id="login-myModal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel">
              <div class="modal-dialog" role="document">
                <div class="modal-content">
                  <div class="modal-header">
                    <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>
                    <h4 class="modal-title" id="login-myModalLabel"></h4>
                  </div>
                  <div class="modal-body" id="login-modal-body"></div>
                  <div class="modal-footer">
                    <button type="button" class="btn btn-default" data-dismiss="modal">关闭</button>
                  </div>
                </div>
              </div>
            </div>
    <!-- 主页巨幕 -->
    <div class="jumbotron">
      <div class="container">
        <h1><?php echo $inner ;?></h1>
        <p>欢迎访问<?php echo $name ;?>内部服务器.</p>
        <?php echo $juminfo;?>
      </div>
    </div>
    <div class="container">
      <!-- Example row of columns -->
      <div class="row">
        <div class="col-md-4">
          <img class="img-circle" src="img/intel.jpg" alt="Generic placeholder image" style="width: 140px; height: 140px;">
          <h2>装机配置</h2>
          <p>装机配置单分为三个档次,高中低档,每个配置下面都有该配置报价日期,请以装机当天报价为准. </p>
          <p><a class="btn btn-default" href="pc_install_config" role="button">查看配置 &raquo;</a></p>
        </div>
        <div class="col-md-4">
          <img class="img-circle" src="img/zhuban.jpg" alt="Generic placeholder image" style="width: 140px; height: 140px;">
          <h2>配件报价</h2>
          <p>报价表每月更新一次,每月报价差距不会太大,店内所售物品均录入数据库,根据产品名字或编号自行查询. </p>
          <p><a class="btn btn-default" href="#" role="button" disabled="disabled">查看报价 &raquo;</a></p>
       </div>
        <div class="col-md-4">
          <img class="img-circle" src="img/rj.jpg" alt="Generic placeholder image" style="width: 140px; height: 140px;">
          <h2>软件下载</h2>
          <p>所有软件均在这里下载,包括了日常办公影音软件,驱动也已经集成到这里,装机后可到这里查找所需软件,软件库每2月更新一次,驱动库则是随时更新.</p>
          <p><a class="btn btn-default" href="download" role="button">查找软件 &raquo;</a></p>
        </div>
      </div>
      <hr>
      <?php include("footer.php"); ?>
    </div> <!-- /container -->
    <script src="js/jquery.min.js"></script>
    <script src="js/bootstrap.min.js"></script>
    <script src="js/ie10-viewport-bug-workaround.js"></script>
  </body>
</html>
